<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org" xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout" layout:decorator="layouts/pui-account-discovery-main">
<div layout:fragment="page-content">
    <form action="/login.do" th:action="@{/login.do}" method="post" role="form" _lpchecked="1">
        <div class="form-group">
            <input class="form-control" id="username" name="username" th:attr="autofocus=${email == null}" th:value="${email}" placeholder="Username" style="margin-top:20px"/>
            <input class="form-control" id="password" name="password" th:attr="autofocus=${email != null}" type="password" placeholder="Password" style="margin-top:20px"/>
            <input th:if="${login_hint}"
                   th:name="login_hint"
                   th:type="hidden"
                   th:value="${login_hint}"/>
            <div class="help-block has-error" style="display: none;">
                Please enter your password
            </div>
        </div>
        <div class="form-group">
            <input class="btn btn-highlight btn-block btn-lg" name="commit" type="submit" value="Sign in"/>
        </div>
    </form>
    <div class="addl-actions txt-c mbxl mtxxl clearfix">
        <div class="action pull-left">
            <a href="/login" th:href="@{/login}"><span class="fa fa-icon fa-chevron-left small"></span>
                Back
            </a></div>
        <div class="action pull-right">
            <a th:unless="${forgotPasswordLink == null}" href="/forgot_password" th:href="@{${forgotPasswordLink}}">Reset password</a>
        </div>
    </div>
</div>
</html>
